From e5841a3c968df83a77ee65d146b535b31cbc1021 Mon Sep 17 00:00:00 2001 From: robertl Date: Tue, 13 Apr 2004 16:34:30 +0000 Subject: [PATCH] Don't clobber xsi schema when merging. --- gpx.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gpx.c b/gpx.c index 95ea894bc..3f141638f 100644 --- a/gpx.c +++ b/gpx.c @@ -802,7 +802,9 @@ gpx_rd_init(const char *fname) * this across reads and we unlock the safety belt from the * leak tester. */ - xsi_schema_loc = strdup(DEFAULT_XSI_SCHEMA_LOC); + if (!xsi_schema_loc) { + xsi_schema_loc = strdup(DEFAULT_XSI_SCHEMA_LOC); + } if (!xsi_schema_loc) { fatal("gpx: Unable to allocate %d bytes of memory.\n", strlen(DEFAULT_XSI_SCHEMA_LOC) + 1); } -- 2.30.2